package com.study.base.lambda.function;

import java.util.function.Supplier;

/**
 * Created by tan on 2017/6/19.
 */
public class SupplierTest {
	public static void main(String[] args) {
		//如果你的lamda表达式非常简单,只有一行,那么你可以不写return, 不加花括号{}, 返回值后面可以不加分号.
		Supplier<String> stringSupplier = ()-> { // ()->"test supplier";
			return "test supplier";
		};

		System.out.println(stringSupplier.get());
	}
}
